package com.boot.redis.common;

import com.fasterxml.uuid.Generators;
import tk.mybatis.mapper.genid.GenId;

/**
 * <p>Title: GenId</p>
 * <p>Description:GenId生成器实现类</p>
 *
 * @author ZhiPeng_Chen
 * @version V1.0
 * @date: 2018/6/15
 */
public class UUIdGenId implements GenId<String> {

    @Override
    public String genId(String table, String column) {
        return Generators
                .timeBasedGenerator()
                .generate()
                .toString()
                .replaceAll("-", "")
                .toUpperCase();
    }
}
